/* 通用样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica Neue', Helvetica, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background-color: #f5f7fa;
    color: #333;
}

/* 登录页面样式 */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    width: 400px;
    max-width: 90%;
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h2 {
    color: #333;
    margin-bottom: 10px;
}

.login-header p {
    color: #666;
    font-size: 14px;
}

.login-form .el-form-item {
    margin-bottom: 25px;
}

.login-btn {
    width: 100%;
    margin-top: 10px;
}

/* 后台管理样式 */
.admin-header {
    background: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 0 20px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

.header-content h2 {
    color: #333;
    margin: 0;
}

.admin-main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.toolbar {
    margin-bottom: 20px;
}

/* 前台样式 */
.front-header {
    background: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 0 20px;
}

.front-main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.filter-section {
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.audio-list {
    margin-top: 20px;
}

.audio-card {
    margin-bottom: 20px;
    transition: transform 0.3s ease;
}

.audio-card:hover {
    transform: translateY(-5px);
}

.audio-title h3 {
    margin: 0;
    color: #333;
    font-size: 16px;
}

.audio-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 15px;
}

.audio-actions {
    text-align: right;
}

.empty-state {
    text-align: center;
    padding: 40px 0;
}

/* 播放器样式 */
.player-content {
    text-align: center;
}

.audio-player {
    width: 100%;
    margin: 20px 0;
}

.player-controls {
    margin-top: 20px;
}

.audio-info {
    color: #666;
    margin: 10px 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        height: auto;
        padding: 10px 0;
    }

    .header-content h2 {
        margin-bottom: 10px;
    }

    .admin-main {
        padding: 10px;
    }

    .front-main {
        padding: 10px;
    }

    .filter-section .el-col {
        margin-bottom: 10px;
    }

    .audio-list .el-col {
        width: 100%;
    }
}

/* Element UI 自定义样式 */
.el-table {
    margin-top: 20px;
}

.el-dialog {
    border-radius: 8px;
}

.el-card {
    border: none;
}

.el-button {
    border-radius: 4px;
}

.el-input__inner,
.el-textarea__inner {
    border-radius: 4px;
}

/* 加载状态 */
.loading-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
}

/* 现代化上传对话框样式 */
.modern-upload-dialog .el-dialog {
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.modern-upload-dialog .el-dialog__header {
    padding: 0;
    border-bottom: none;
}

.modern-upload-dialog .el-dialog__body {
    padding: 0;
}

.dialog-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 24px;
    border-radius: 12px 12px 0 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.dialog-header .header-icon {
    font-size: 24px;
}

.dialog-header span {
    font-size: 18px;
    font-weight: 600;
}

.modern-form {
    padding: 24px;
}

.modern-form .el-form-item {
    margin-bottom: 20px;
}

.modern-form .el-form-item__label {
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

.modern-select .el-input__inner,
.modern-input .el-input__inner {
    border-radius: 8px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
    height: 40px;
    line-height: 40px;
}

.modern-select .el-input__inner:focus,
.modern-input .el-input__inner:focus {
    border-color: #409eff;
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.1);
}

.modern-textarea .el-textarea__inner {
    border-radius: 8px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
    font-family: inherit;
}

.modern-textarea .el-textarea__inner:focus {
    border-color: #409eff;
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.1);
}

.modern-switch .el-switch__label {
    color: #666;
}

.modern-switch .el-switch__label.is-active {
    color: #409eff;
}

/* 文件上传区域样式 */
.file-upload-item .el-form-item__content {
    line-height: normal;
}

.upload-area {
    border: 2px dashed #dcdfe6;
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafbfc;
}

.upload-area:hover {
    border-color: #409eff;
    background: #f0f7ff;
}

.upload-content .upload-icon {
    font-size: 48px;
    color: #c0c4cc;
    margin-bottom: 12px;
}

.upload-text {
    font-size: 16px;
    color: #333;
    margin-bottom: 8px;
    font-weight: 500;
}

.upload-hint {
    font-size: 12px;
    color: #909399;
}

.file-selected {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: white;
    border-radius: 8px;
    border: 1px solid #e1e8ed;
}

.file-icon {
    font-size: 24px;
    color: #409eff;
    margin-right: 12px;
}

.file-info {
    flex: 1;
    text-align: left;
}

.file-name {
    font-size: 14px;
    color: #333;
    font-weight: 500;
    margin-bottom: 4px;
}

.file-size {
    font-size: 12px;
    color: #909399;
}

.change-file-btn {
    color: #409eff;
    font-size: 12px;
}

.change-file-btn:hover {
    color: #66b1ff;
}

/* 对话框底部按钮 */
.dialog-footer {
    padding: 16px 24px;
    border-top: 1px solid #e1e5e9;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.cancel-btn {
    border-radius: 6px;
    padding: 10px 20px;
    border: 1px solid #dcdfe6;
}

.upload-btn {
    border-radius: 6px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.upload-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.upload-btn:disabled {
    background: #c0c4cc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .modern-upload-dialog .el-dialog {
        width: 90% !important;
        margin: 5% auto !important;
    }

    .modern-form {
        padding: 16px;
    }

    .file-selected {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

/* 搜索框样式优化 */
.search-input .el-input__inner {
    border-radius: 8px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
    padding-left: 35px;
}

.search-input .el-input__inner:focus {
    border-color: #409eff;
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.1);
}

.search-icon {
    color: #909399;
    font-size: 16px;
    margin-left: 8px;
}

.search-btn {
    border-radius: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    height: 40px;
    font-weight: 500;
}

.search-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 分类标签样式 */
.audio-meta {
    margin: 10px 0;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.category-tag {
    background: #409eff;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.subcategory-tag {
    background: #67c23a;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
}

/* 音频播放控制样式 */
.audio-player-controls {
    margin-top: 15px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.play-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.play-btn {
    width: 36px;
    height: 36px;
    font-size: 14px;
}

.time-display {
    font-size: 12px;
    color: #666;
    font-family: 'Courier New', monospace;
}

.speed-select {
    width: 70px;
}

.speed-select .el-input__inner {
    height: 28px;
    line-height: 28px;
    font-size: 12px;
}

.progress-controls {
    margin-bottom: 10px;
}

.audio-progress {
    margin: 0;
}

.audio-progress .el-slider__runway {
    height: 4px;
    background-color: #e4e7ed;
}

.audio-progress .el-slider__bar {
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.audio-progress .el-slider__button {
    width: 12px;
    height: 12px;
    border: 2px solid #667eea;
}

.download-controls {
    text-align: center;
}

.download-btn {
    background: linear-gradient(135deg, #67c23a 0%, #85ce61 100%);
    border: none;
    color: white;
    border-radius: 6px;
    padding: 6px 12px;
}

.download-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(103, 194, 58, 0.3);
}

/* 音频卡片悬停效果 */
.audio-card {
    transition: all 0.3s ease;
    border: 1px solid #e1e5e9;
}

.audio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: #409eff;
}

.audio-title h3 {
    margin: 0;
    color: #333;
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.audio-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .play-controls {
        flex-wrap: wrap;
        gap: 8px;
    }

    .time-display {
        order: 3;
        flex-basis: 100%;
        text-align: center;
    }
}

/* 进度条样式 */
.audio-progress {
    margin: 8px 0;
    cursor: pointer;
}

.audio-progress .el-slider__runway {
    height: 6px;
    background-color: #e4e7ed;
    border-radius: 3px;
}

.audio-progress .el-slider__bar {
    height: 6px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 3px;
}

.audio-progress .el-slider__button {
    width: 16px;
    height: 16px;
    border: 2px solid #667eea;
    background-color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.audio-progress .el-slider__button-wrapper {
    cursor: grab;
    z-index: 100;
}

.audio-progress .el-slider__button-wrapper:active {
    cursor: grabbing;
}

.audio-progress .el-slider__button-wrapper:hover .el-slider__button {
    transform: scale(1.2);
}

/* 确保进度条区域可点击 */
.audio-progress .el-slider__runway:hover {
    background-color: #d8dce5;
}

.audio-progress .el-slider__runway:hover .el-slider__bar {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}